package com.task.mapper;

import com.task.bean.Rank;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.task.vo.RankNameVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author liuzhe
 * @since 2021-04-10
 */
public interface RankMapper extends BaseMapper<Rank> {

    List<RankNameVo> queryNameAndRankOrderByRank();

    List<Rank> queryByStuId(@Param("id") Integer id);

    void updateByStuId(@Param("stuId") Integer stuId,@Param("score") Double score);

    void insertNew(@Param("rank") Rank rank);
}
